/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package us.oh.k12.wkw.robot.command;

/**
 *
 * @author Team4145
 */
public class DriveStraightReverseCmd extends CommandBase {

    private double timeOut;

    public DriveStraightReverseCmd(double pTimeout) {

        super("DriveStraightReverseCmd");
        this.timeOut = pTimeout;
        this.requires(this.getDriveSystem());

    }

    protected void initialize() {

        this.setTimeout(this.timeOut);

    }

    protected void execute() {

        this.getDriveSystem().straight(.8);

    }
    
    protected void end() {
        this.getDriveSystem().stop();
    }

    protected boolean isFinished() {

        return this.isTimedOut();

    }
}
